The present invention relates to a method and apparatus for control and communication between computer systems linked through a network and, in particular, to a method and apparatus for communicating through a public network with automation server objects from Java applets via active server pages.
Computers are commonly interconnected by networks so that one computer of the network, often referred to as a client, can call upon or control another computer, which is often referred to as a server, for the other computer to provide some service or function for the first computer. Such systems require that at least some of the computers in the system, such as one or more client computers, be capable of monitoring, managing and maintaining the server computers, which in turn requires an inter-computer communication and control facility capable of operating through the network and of supporting monitoring, management and maintenance functions. This problem of communication monitoring, management and maintenance between computers has been solved in a variety of ways for proprietary systems, that is, systems using private networks, which typically provide proprietary or private communications facilities for these functions.
The requirement for communications capable of supporting monitoring, management and maintenance functions between computers linked through public networks, such as the Internet or telephonic systems and other public area networks, however, remains a problem. Such communications are often provided through specialized or proprietary communications programs, some of which additionally require specialized or proprietary hardware components, or through adaptations of communications programs, such as KERMIT, that were originally intended only for basic functions, such as the transfer of files. These methods, however, not only increase the cost and complexity of the computers and the systems, but have been generally unsatisfactory in the case of communications programs that have been adapted from other purposes.
In addition, the use of such specialized or proprietary communications programs effectively bar any computer not provided with the specific communication program, and perhaps hardware, from operating in the networked system unless the specific program, and possibly hardware components, has been installed in the computer. This is a severe disadvantage in many applications, such as client computers networked to server computers through the Internet, as it is often desirable to be able to rapidly and easily integrate client computers into an Internet based system without the addition of new software components in each client, and certainly without requiring the installation of specialized hardware components.
The prior art has attempted to solve these problems, with results that have generally been unsatisfactory. For example, Common Gateway Interface (CGI) is a standard interface for running external programs or gateways on a World Wide Web information server. This method extends the functionality of a Web server by executing programs or scripts on a Web server in response to requests from a Web browser residing on a client of the server wherein the browser sends form data to a CGI script or the server and the script on the server processes the data and sends the results back in a HTML page. The CGI method, however, has been unsatisfactory because, first, it is adapted only to performing predefined operations on data from a client, but does not otherwise allow a client to control operations of the server. In addition, and while the CGI method returns data to the client, it does not support dynamic updating of functions in the requesting client.
The Internet Server Application Program Interface (ISAPI) server extensions method provides an alternative to the use of CGI applications for Internet servers wherein Internet Server Applications (ISAs) run in the same address space as the HTTP server and have access to all of the resources available to the HTTP server. The use of ISAPI server extensions has, however, been unsatisfactory because this facility is a special purpose extension to a conventional Web browser and is found in and is compatible only with a limited number of Web browsers.
Yet another alternative, Remote Method Invocation, is a Java compatible mechanism for distributed client/server applications that allow Java client applets to remotely access Java server objects and invoke the methods of those objects. Again, however, Remote Method Invocation is an extension to conventional Web browsers and is found in and is compatible with only a limited number of Web browsers. In addition, this method does not allow a browser to directly access native automation server objects on a server, but only Java server objects, so that a Java server application can interface with the server system native code, such as native automation server objects on the server, only through specially developed, additional interface layer.
The present invention provides a solution to these and other problems of the prior art.
The present invention is directed to a method for use in a system including a client system and a server system interconnected through a network for controlling an operation of the server system by the client system. The server system includes a network server facility to control network communications and a server resident scripting utility for creating and executing server scripts and the client system includes a browser for communicating with the server system through the network. The server system further includes a resident server page that includes a scripting for creating a server object, wherein the server object includes a server method for controlling an operation of the server system, and an applet for invoking the server page and corresponding to a server method to be executed in the server system.
According to the present invention, a translated server page is downloaded from the server system to the client system wherein the translated server page corresponds to the server page resident in the server system and the script in the translated server page is translated into a form executable by the browser resident in the client system. In the client system, an input is provided to invoke the applet, which in turn invokes the script of the translated server page. Thereafter, the server system responds to operation of the translated script in the translated server page by creating an instance of the server object and executing the server method corresponding to the applet. The translated script in the translated server may also pass an argument to the server object after the server object is invoked. In addition, the server method may return data to the translated server page, the applet may read the returned data and the state of the applet may be updated according to the returned data.